package com.boot.start.entity;

import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.io.Serializable;

/**
 * @author 墨龙吟
 * @version 1.0.0
 * @ClassName Employee.java
 * @Email 2354713722@qq.com
 * @Description TODO
 * @createTime 2020年05月18日 - 16:26
 */
@Getter
@Setter
@Entity
@Accessors(chain = true)
@Table(name = "db_employee")
public class Employee implements Serializable {

    private static final long serialVersionUID = -3629827996122776621L;

    /**
     * 主键
     */
    @Id
    @GeneratedValue(generator = "system-uuid")
    @GenericGenerator(name = "system-uuid", strategy = "uuid.hex")
    @Column(name = "emp_id", nullable = false, length = 64)
    private String empId;

    /**
     * 名字
     */
    @Column(name = "emp_name", length = 25)
    private String empName;

    /**
     * 年龄
     */
    @Column(name = "emp_age", length = 2)
    private Integer empAge;

    /**
     * 备注
     */
    @Column(name = "emp_brief", length = 255)
    private String empBrief;

    /**
     * 性别
     */
    @Column(name = "emp_sex", length = 1)
    private Boolean empSex;

}
